A disk drive is an information storage device. A disk drive includes one or more disks clamped to a rotating spindle, and at least one head for reading information representing data from and/or writing data to the surfaces of each disk. More specifically, storing data includes writing information representing data to portions of tracks on a disk so that it can be subsequently read and retrieved. Disk drives associated with a computing system generally execute write commands from a host computer. By the time a write command from a host computer passes through a read/write channel of the disk drive, the write command includes specific information including the location on the disk where the specific information will be written. Executing write commands as they arrive can be done. However, many times it is not necessary to write information to the disk immediately since most of the time data to be written does not immediately need to be read. In addition, a majority of the time a disk drive is in operation, it is reading information representing data. Switching from reading information to writing information during read operations each time a write command is received would be time consuming, inefficient, and many times, would adversely effect performance of the disk drive. As a result, the host or the disk drive will store or group individual write commands in a write cache, rather than write each of the commands as they arrive. When the write cache is full or at a selected time, a command is given to empty the write cache of the write commands. The command is also called a Flush-Cache command.
In response to the Flush-Cache command, the disk drive writes the data associated with the write commands to the designated specific locations on the disk of the disk drive. When all the write commands have been written to their designated locations, the disk drive informs the host computer that the Flush-Cache command is complete.
Various performance parameters are used to measure the speed of a disk drive. One of the performance parameters is how fast the disk drive responds to write commands. Some of the performance tests for writing include a response time for completing one or more Flush-Cache commands. Determining a way to quickly respond to a Flush-Cache command or multiple Flush-Cache commands can enhance one of the performance factors associated with a disk drive. Of course, the response must insure that the data is stored and can be read back in all or most circumstances since losing data negatively how a user of a disk drive perceives the disk drive. Therefore, the data written in response to a Flush-Cache command must be retrievable even if a power outage, sudden acceleration of the disk drive, or a similar event occurs in the middle of executing the Flush-Cache command or shortly after signaling that the Flush-Cache command is complete.
The description set out herein illustrates the various embodiments of the invention and such description is not intended to be construed as limiting in any manner.